package com.errol.batchprocessor.employeeaddition.advisorimpl.demand.payload;

import com.renjia.entity.BusDemandEmployeeTemp;
import com.renjia.enums.DemandEmployeeFailTypeEnum;
import com.renjia.enums.DocumentTypeEnum;
import com.renjia.service.module.employeeaddition.advisorimpl.common.payload.AbstractEmployeeSinglePayload;
import lombok.Getter;

/**
 * 接单导入单条记录数据
 *
 * @author zhang xiao bin
 * @version v1.0
 * @date 2021/03/01
 * @since v5.0.6
 **/
@Getter
public class DemandEmployeeSinglePayload extends AbstractEmployeeSinglePayload<BusDemandEmployeeTemp> {

    private DemandEmployeeFailTypeEnum demandEmployeeFailTypeEnum;

    public DemandEmployeeSinglePayload(BusDemandEmployeeTemp singleEntity) {
        super(singleEntity, singleEntity.getName(), DocumentTypeEnum.getEnumByCode(singleEntity.getDocumentType()), singleEntity.getDocumentNumber(),
                singleEntity.getBankCard(), singleEntity.getMobile());
        this.demandEmployeeFailTypeEnum = DemandEmployeeFailTypeEnum.DEFAULT;
    }

    public void setDemandEmployeeFailTypeEnum(DemandEmployeeFailTypeEnum demandEmployeeFailTypeEnum) {
        this.demandEmployeeFailTypeEnum = demandEmployeeFailTypeEnum;
    }
}
